package org.zhengquan.dto;

import com.google.common.collect.Lists;
import lombok.Getter;
import lombok.Setter;
import org.springframework.beans.BeanUtils;
import org.zhengquan.pojo.SysDept;

import java.util.List;

/**
 * @author zhengquan
 * @date 2017/10/27
 */
@Getter
@Setter
public class DeptLevelDto extends SysDept {
    private List<DeptLevelDto> list = Lists.newArrayList();

    public static DeptLevelDto adapt(SysDept sysDept) {
        DeptLevelDto deptLevelDto = new DeptLevelDto();
        BeanUtils.copyProperties(sysDept,deptLevelDto);
        return deptLevelDto;
    }
}
